<%--
  Created by IntelliJ IDEA.
  User: wwh
  Date: 2017/9/6
  Time: 11:51
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>求职信息</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="format-detection" content="telephone=no">
    <link rel="stylesheet" type="text/css" href="../../static/common/layui/css/layui.css" media="all">
    <link rel="stylesheet" type="text/css" href="../../static/common/global.css" media="all">
</head>
<body>
<div class="admin-main">
    <blockquote class="layui-elem-quote">
    </blockquote>
    <fieldset class="layui-elem-field">
        <legend>求职列表</legend>
        <div class="layui-form">
            <table class="layui-table">
                <thead>
                <tr>
                    <%--<th>招聘信息</th>--%>
                    <th>用人单位</th>
                    <th>岗位</th>
                    <th>状态</th>
                </tr>
                </thead>
                <tbody id="content"></tbody>
            </table>
        </div>
    </fieldset>
    <div class="admin-table-page">
        <div id="paged" class="page"></div>
    </div>
</div>
<script type="text/html" id="tpl">
    {{# layui.each(d.data,function(index,item){ }}
    <tr>
        <td>{{ item.orgInfoFullName || "-" }}</td>
        <td>{{ item.positionTypeName || "-" }}</td>
        <td>
            {{# if(item.jobApply.status == 1){ }}
            投递中
            {{# } }}
            {{# if(item.jobApply.status == 2){ }}
            被拒绝
            {{# } }}
            {{# if(item.jobApply.status == 3){ }}
            已录用
            {{# } }}
        </td>
    </tr>
    {{# }); }}
</script>
<script>
    var userId = ${sessionScope.currentUser.getId()};
</script>
<script type="text/javascript" src="../../static/common/layui/layui.js"></script>
<script src="../../static/common/axios.min.js"></script>
<script src="../../static/common/vue.min.js"></script>
<script>
    layui.config({
        base: '../../static/js/layuiModulesEX/'
    });
    layui.use(['paging','laytpl','form'],function () {
        var $ = layui.jquery,
            paging = layui.paging(),
            layer = layui.layer,
            laytpl = layui.laytpl,
            form = layui.form;

        paging.init({
            url:'/jobApply/findByCondition',
            elem:"#content",
            params:{
                stid:userId
            },
            contentType : "application/json; charset=utf-8",
            type: 'POST',
            tempElem: '#tpl', //模块容器
            pageConfig: { //分页参数配置
                elem: 'paged', //分页容器
                pageSize:10 //分页大小
            },
            success:function () {
//                alert('渲染成功');
            },
            fail:function (msg) {
//                alert('获取数据失败');
            },
            complate:function () {
//                alert("处理完成");
                /**
                 * 绑定操作（招聘信息查看/用人单位信息查看）
                 */
                $('#content').children('tr').each(function () {

                });
            }
        });


    });
</script>
</body>
</html>
